package com.bgIntlgn.client.entity.sells;

import java.util.Date;

import yuhuibear.poat.annotations.action.AutoGenerateValue;
import yuhuibear.poat.annotations.relation.Field;
import yuhuibear.poat.annotations.relation.Table;
import yuhuibear.poat.object.bean.Bean;

/**
 * 客户报价表
 * 
 * @author yuhui
 * 
 */

@Table(name = "quotations", constrain = "")
public class Quotation implements Bean {

	@AutoGenerateValue(skipOnNull = true, sqlToGet = "select currval('quotations_id_seq')")
	@Field(name = "id", type = "bigserial", constrain = "primary key ")
	private Long id;

	/**
	 * 销售人员
	 */
	@Field(name = "creater", type = "int8", constrain = "not null references employees(id)  on update cascade on delete cascade")
	private Long creater;

	/**
	 * 创建日期
	 */
	@Field(name = "create_date", type = "timestamp", constrain = "")
	private Date createDate;

	@Field(name = "serial_number", type = "varchar(80)", constrain = "unique")
	private String serialNumber;

	@Field(name = "custom_id", type = "int8", constrain = " not null references customs(id)  on update cascade on delete cascade")
	private Long customId;

	@Field(name = "contactor_id", type = "int8", constrain = " not null references contactors(id)  on update cascade on delete cascade")
	private Long contactorId;

	/**
	 * 报价单备注
	 */
	@Field(name = "comment", type = "varchar(1000)", constrain = "")
	private String comment;

	public Long getId() {
		return this.id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public Long getCreater() {
		return this.creater;
	}

	public void setCreater(Long creater) {
		this.creater = creater;
	}

	public Date getCreateDate() {
		return this.createDate;
	}

	public void setCreateDate(Date createDate) {
		this.createDate = createDate;
	}

	public String getSerialNumber() {
		return this.serialNumber;
	}

	public void setSerialNumber(String serialNumber) {
		this.serialNumber = serialNumber;
	}

	public Long getCustomId() {
		return this.customId;
	}

	public void setCustomId(Long customId) {
		this.customId = customId;
	}

	public Long getContactorId() {
		return this.contactorId;
	}

	public void setContactorId(Long contactorId) {
		this.contactorId = contactorId;
	}

	public String getComment() {
		return this.comment;
	}

	public void setComment(String comment) {
		this.comment = comment;
	}

}
